//
//  SectionLineView.m
//  Cunli
//
//  Created by ZhanyaaLi on 15/12/15.
//  Copyright © 2015年 lilubin. All rights reserved.
//

#import "SectionLineView.h"
#import "UIColor+expanded.h"

@implementation SectionLineView

- (void)drawRect:(CGRect)rect {
    // Drawing code
    [self setBackgroundColor:[UIColor colorWithHexString:@"0xf6f6f6"]];
    CGContextRef context = UIGraphicsGetCurrentContext();
    CGContextSetLineCap(context, kCGLineCapRound);
    CGContextSetLineWidth(context, 1);
    CGContextSetAllowsAntialiasing(context, true);
    CGContextSetRGBStrokeColor(context, 221.0 / 255.0, 221.0 / 255.0, 221.0 / 255.0, 1.0);
    CGContextBeginPath(context);
    
    CGContextMoveToPoint(context, 13, self.frame.size.height * 1.0 / 2.0);
    CGContextAddLineToPoint(context, self.frame.size.width - 13, self.frame.size.height * 1.0 / 2.0);
    
    CGContextStrokePath(context);
}


@end
